package com.novel.crawler.client;


import com.novel.crawler.utils.HttpClientUtil;
import com.novel.crawler.utils.JsoupUtil;

import java.io.IOException;
import java.util.List;
import java.util.UUID;

public class crawler {

    public static void main(String[] args) throws IOException {
/*        HttpClientUtil util = new HttpClientUtil();
        String url = "http://www.xbiquge.la/7/7877/";
        String html = util.execute(url, true);
        String format = "div#list > dl > dd > a";
        List<String> list = JsoupUtil.ParseHref(html, format, url);

        String novelId = "de7b8b07-ca24-4f28-8cf6-20880b43cb4a";

        list.forEach(str -> {
            try {
                String execute = util.execute(str, true);

                String title = JsoupUtil.ParseText(execute, "h1");
                String content = JsoupUtil.ParseText(execute, "div#content");
                String chapterId = UUID.randomUUID().toString();

            } catch (IOException e) {
                e.printStackTrace();
            }
        });*/

        String uuid = UUID.randomUUID().toString();
        System.out.println(uuid.length());
        System.out.println(uuid);
/*        String str = "848f7fe9-27ce-4178-aaaa-6d5f7a86b11d";
        System.out.println(str.length());*/
    }
}
